package com.ifnk.portaljava.hlyt.dao;

import com.ifnk.portaljava.hlyt.beans.Behaviour;

import java.sql.Connection;
import java.util.List;

public interface IBehaviourJdbcDAO {

	int save(int userId, String userName, Connection conn) throws Exception;

	// 查找所有的字段并且根据参数是否返回协议的集合
	public List findAllCDRFields(Boolean haveProtocols) throws Exception;

	// 根据用户定制的字段查询字段的内容
	public List findCDRFieldByUserSelectedField(String field) throws Exception;

	// 根据用户的id查找用户的属性记录，如果存在记录则返回记录否则返回null
	public Behaviour findUserFieldByUserId(int id) throws Exception;

	public void updateUserFields(String selectedField, int userId,
			Connection conn) throws Exception;

	void updateLastModule(int id, String url, Connection conn) throws Exception;

	void deleteByUserId(int userId, Connection conn) throws Exception;
	public List findAllCDRFieldsName();
}
